<!DOCTYPE html>
<html lang="en">
  <head>
    <title>UIButton Extension Reference</title>
    <link rel="stylesheet" type="text/css" href="../css/jazzy.css" />
    <link rel="stylesheet" type="text/css" href="../css/highlight.css" />
    <meta charset="utf-8">
    <script src="../js/jquery.min.js" defer></script>
    <script src="../js/jazzy.js" defer></script>
    
    <script src="../js/lunr.min.js" defer></script>
    <script src="../js/typeahead.jquery.js" defer></script>
    <script src="../js/jazzy.search.js" defer></script>
  </head>
  <body>

    <a name="//apple_ref/swift/Extension/UIButton" class="dashAnchor"></a>

    <a title="UIButton Extension Reference"></a>

    <header class="header">
      <p class="header-col header-col--primary">
        <a class="header-link" href="../index.html">
          AlamofireImage 4.2.0 Docs
        </a>
         (77% documented)
      </p>
    
      <p class="header-col--secondary">
        <form role="search" action="../search.json">
          <input type="text" placeholder="Search documentation" data-typeahead>
        </form>
      </p>
    
        <p class="header-col header-col--secondary">
          <a class="header-link" href="https://github.com/Alamofire/AlamofireImage">
            <img class="header-icon" src="../img/gh.png"/>
            View on GitHub
          </a>
        </p>
    
        <p class="header-col header-col--secondary">
          <a class="header-link" href="dash-feed://https%3A%2F%2Falamofire.github.io%2FAlamofireImage%2Fdocsets%2FAlamofireImage.xml">
            <img class="header-icon" src="../img/dash.png"/>
            Install in Dash
          </a>
        </p>
    </header>

    <p class="breadcrumbs">
      <a class="breadcrumb" href="../index.html">AlamofireImage Reference</a>
      <img class="carat" src="../img/carat.png" />
      UIButton Extension Reference
    </p>

    <div class="content-wrapper">
      <nav class="navigation">
        <ul class="nav-groups">
          <li class="nav-group-name">
            <a class="nav-group-name-link" href="../Classes.html">Classes</a>
            <ul class="nav-group-tasks">
              <li class="nav-group-task">
                <a class="nav-group-task-link" href="../Classes/AutoPurgingImageCache.html">AutoPurgingImageCache</a>
              </li>
              <li class="nav-group-task">
                <a class="nav-group-task-link" href="../Classes/ImageDownloader.html">ImageDownloader</a>
              </li>
              <li class="nav-group-task">
                <a class="nav-group-task-link" href="../Classes/ImageDownloader/DownloadPrioritization.html">– DownloadPrioritization</a>
              </li>
              <li class="nav-group-task">
                <a class="nav-group-task-link" href="../Classes/ImageResponseSerializer.html">ImageResponseSerializer</a>
              </li>
              <li class="nav-group-task">
                <a class="nav-group-task-link" href="../Classes/RequestReceipt.html">RequestReceipt</a>
              </li>
            </ul>
          </li>
          <li class="nav-group-name">
            <a class="nav-group-name-link" href="../Enums.html">Enumerations</a>
            <ul class="nav-group-tasks">
              <li class="nav-group-task">
                <a class="nav-group-task-link" href="../Enums/AFIError.html">AFIError</a>
              </li>
            </ul>
          </li>
          <li class="nav-group-name">
            <a class="nav-group-name-link" href="../Extensions.html">Extensions</a>
            <ul class="nav-group-tasks">
              <li class="nav-group-task">
                <a class="nav-group-task-link" href="../Extensions/AlamofireExtension.html">AlamofireExtension</a>
              </li>
              <li class="nav-group-task">
                <a class="nav-group-task-link" href="../Extensions/DataRequest.html">DataRequest</a>
              </li>
              <li class="nav-group-task">
                <a class="nav-group-task-link" href="../Extensions/DataRequest.html">DataRequest</a>
              </li>
              <li class="nav-group-task">
                <a class="nav-group-task-link" href="../Extensions/UIButton.html">UIButton</a>
              </li>
              <li class="nav-group-task">
                <a class="nav-group-task-link" href="../Extensions/UIImage.html">UIImage</a>
              </li>
              <li class="nav-group-task">
                <a class="nav-group-task-link" href="../Extensions/UIImageView.html">UIImageView</a>
              </li>
              <li class="nav-group-task">
                <a class="nav-group-task-link" href="../Extensions/UIImageView/ImageTransition.html">– ImageTransition</a>
              </li>
            </ul>
          </li>
          <li class="nav-group-name">
            <a class="nav-group-name-link" href="../Protocols.html">Protocols</a>
            <ul class="nav-group-tasks">
              <li class="nav-group-task">
                <a class="nav-group-task-link" href="../Protocols/CompositeImageFilter.html">CompositeImageFilter</a>
              </li>
              <li class="nav-group-task">
                <a class="nav-group-task-link" href="../Protocols/CoreImageFilter.html">CoreImageFilter</a>
              </li>
              <li class="nav-group-task">
                <a class="nav-group-task-link" href="../Protocols/ImageCache.html">ImageCache</a>
              </li>
              <li class="nav-group-task">
                <a class="nav-group-task-link" href="../Protocols/ImageFilter.html">ImageFilter</a>
              </li>
              <li class="nav-group-task">
                <a class="nav-group-task-link" href="../Protocols/ImageRequestCache.html">ImageRequestCache</a>
              </li>
              <li class="nav-group-task">
                <a class="nav-group-task-link" href="../Protocols/Roundable.html">Roundable</a>
              </li>
              <li class="nav-group-task">
                <a class="nav-group-task-link" href="../Protocols/Sizable.html">Sizable</a>
              </li>
            </ul>
          </li>
          <li class="nav-group-name">
            <a class="nav-group-name-link" href="../Structs.html">Structures</a>
            <ul class="nav-group-tasks">
              <li class="nav-group-task">
                <a class="nav-group-task-link" href="../Structs/AspectScaledToFillSizeCircleFilter.html">AspectScaledToFillSizeCircleFilter</a>
              </li>
              <li class="nav-group-task">
                <a class="nav-group-task-link" href="../Structs/AspectScaledToFillSizeFilter.html">AspectScaledToFillSizeFilter</a>
              </li>
              <li class="nav-group-task">
                <a class="nav-group-task-link" href="../Structs/AspectScaledToFillSizeWithRoundedCornersFilter.html">AspectScaledToFillSizeWithRoundedCornersFilter</a>
              </li>
              <li class="nav-group-task">
                <a class="nav-group-task-link" href="../Structs/AspectScaledToFitSizeFilter.html">AspectScaledToFitSizeFilter</a>
              </li>
              <li class="nav-group-task">
                <a class="nav-group-task-link" href="../Structs/BlurFilter.html">BlurFilter</a>
              </li>
              <li class="nav-group-task">
                <a class="nav-group-task-link" href="../Structs/CircleFilter.html">CircleFilter</a>
              </li>
              <li class="nav-group-task">
                <a class="nav-group-task-link" href="../Structs/DynamicCompositeImageFilter.html">DynamicCompositeImageFilter</a>
              </li>
              <li class="nav-group-task">
                <a class="nav-group-task-link" href="../Structs/DynamicImageFilter.html">DynamicImageFilter</a>
              </li>
              <li class="nav-group-task">
                <a class="nav-group-task-link" href="../Structs/RoundedCornersFilter.html">RoundedCornersFilter</a>
              </li>
              <li class="nav-group-task">
                <a class="nav-group-task-link" href="../Structs/ScaledToSizeCircleFilter.html">ScaledToSizeCircleFilter</a>
              </li>
              <li class="nav-group-task">
                <a class="nav-group-task-link" href="../Structs/ScaledToSizeFilter.html">ScaledToSizeFilter</a>
              </li>
              <li class="nav-group-task">
                <a class="nav-group-task-link" href="../Structs/ScaledToSizeWithRoundedCornersFilter.html">ScaledToSizeWithRoundedCornersFilter</a>
              </li>
            </ul>
          </li>
          <li class="nav-group-name">
            <a class="nav-group-name-link" href="../Typealiases.html">Type Aliases</a>
            <ul class="nav-group-tasks">
              <li class="nav-group-task">
                <a class="nav-group-task-link" href="../Typealiases.html#/s:14AlamofireImage15AFIDataResponsea">AFIDataResponse</a>
              </li>
              <li class="nav-group-task">
                <a class="nav-group-task-link" href="../Typealiases.html#/s:14AlamofireImage9AFIResulta">AFIResult</a>
              </li>
              <li class="nav-group-task">
                <a class="nav-group-task-link" href="../Typealiases.html#/s:14AlamofireImage16AnimationOptionsa">AnimationOptions</a>
              </li>
              <li class="nav-group-task">
                <a class="nav-group-task-link" href="../Typealiases.html#/s:14AlamofireImage12ControlStatea">ControlState</a>
              </li>
              <li class="nav-group-task">
                <a class="nav-group-task-link" href="../Typealiases.html#/Image">Image</a>
              </li>
              <li class="nav-group-task">
                <a class="nav-group-task-link" href="../Typealiases.html#/s:14AlamofireImage0B0a">Image</a>
              </li>
            </ul>
          </li>
        </ul>
      </nav>
      <article class="main-content">

        <section class="section">
          <div class="section-content top-matter">
            <h1>UIButton</h1>
              <div class="declaration">
                <div class="language">
                  
                  <pre class="highlight swift"><code><span class="kd">extension</span> <span class="kt">UIButton</span><span class="p">:</span> <span class="kt">AlamofireExtended</span></code></pre>

                </div>
              </div>
            
          </div>
        </section>

        <section class="section">
          <div class="section-content">
            <div class="task-group">
              <div class="task-name-container">
                <a name="/Deprecated"></a>
                <a name="//apple_ref/swift/Section/Deprecated" class="dashAnchor"></a>
                <div class="section-name-container">
                  <a class="section-name-link" href="#/Deprecated"></a>
                  <h3 class="section-name"><p>Deprecated</p>
</h3>
                </div>
              </div>
              <ul class="item-container">
                <li class="item">
                  <div>
                    <code>
                    <a name="/s:So8UIButtonC14AlamofireImageE18af_imageDownloaderAC0cF0CSgvp"></a>
                    <a name="//apple_ref/swift/Property/af_imageDownloader" class="dashAnchor"></a>
                    <a class="token" href="#/s:So8UIButtonC14AlamofireImageE18af_imageDownloaderAC0cF0CSgvp">af_imageDownloader</a>
                    </code>
                  </div>
                  <div class="height-container">
                    <div class="pointer-container"></div>
                    <section class="section">
                      <div class="pointer"></div>
                      <div class="abstract">
                        <p>Undocumented</p>

                      </div>
                      <div class="declaration">
                        <h4>Declaration</h4>
                        <div class="language">
                          <p class="aside-title">Swift</p>
                          <pre class="highlight swift"><code><span class="kd">public</span> <span class="k">var</span> <span class="nv">af_imageDownloader</span><span class="p">:</span> <span class="kt"><a href="../Classes/ImageDownloader.html">ImageDownloader</a></span><span class="p">?</span> <span class="p">{</span> <span class="k">get</span> <span class="k">set</span> <span class="p">}</span></code></pre>

                        </div>
                      </div>
                    </section>
                  </div>
                </li>
                <li class="item">
                  <div>
                    <code>
                    <a name="/s:So8UIButtonC14AlamofireImageE09af_sharedC10DownloaderAC0cF0CvpZ"></a>
                    <a name="//apple_ref/swift/Variable/af_sharedImageDownloader" class="dashAnchor"></a>
                    <a class="token" href="#/s:So8UIButtonC14AlamofireImageE09af_sharedC10DownloaderAC0cF0CvpZ">af_sharedImageDownloader</a>
                    </code>
                  </div>
                  <div class="height-container">
                    <div class="pointer-container"></div>
                    <section class="section">
                      <div class="pointer"></div>
                      <div class="abstract">
                        <p>Undocumented</p>

                      </div>
                      <div class="declaration">
                        <h4>Declaration</h4>
                        <div class="language">
                          <p class="aside-title">Swift</p>
                          <pre class="highlight swift"><code><span class="kd">public</span> <span class="kd">class</span> <span class="k">var</span> <span class="nv">af_sharedImageDownloader</span><span class="p">:</span> <span class="kt"><a href="../Classes/ImageDownloader.html">ImageDownloader</a></span> <span class="p">{</span> <span class="k">get</span> <span class="k">set</span> <span class="p">}</span></code></pre>

                        </div>
                      </div>
                    </section>
                  </div>
                </li>
                <li class="item">
                  <div>
                    <code>
                    <a name="/s:So8UIButtonC14AlamofireImageE06af_setC03for3url8cacheKey011placeholderC010serializer6filter8progress0M5Queue10completionySo14UIControlStateV_10Foundation3URLVSSSgSo7UIImageCSgAC0C18ResponseSerializerCSgAC0C6Filter_pSgySo10NSProgressCcSgSo17OS_dispatch_queueCy0B004DataU0VyAuC8AFIErrorOGcSgtF"></a>
                    <a name="//apple_ref/swift/Method/af_setImage(for:url:cacheKey:placeholderImage:serializer:filter:progress:progressQueue:completion:)" class="dashAnchor"></a>
                    <a class="token" href="#/s:So8UIButtonC14AlamofireImageE06af_setC03for3url8cacheKey011placeholderC010serializer6filter8progress0M5Queue10completionySo14UIControlStateV_10Foundation3URLVSSSgSo7UIImageCSgAC0C18ResponseSerializerCSgAC0C6Filter_pSgySo10NSProgressCcSgSo17OS_dispatch_queueCy0B004DataU0VyAuC8AFIErrorOGcSgtF">af_setImage(for:<wbr>url:<wbr>cacheKey:<wbr>placeholderImage:<wbr>serializer:<wbr>filter:<wbr>progress:<wbr>progressQueue:<wbr>completion:<wbr>)</a>
                    </code>
                  </div>
                  <div class="height-container">
                    <div class="pointer-container"></div>
                    <section class="section">
                      <div class="pointer"></div>
                      <div class="abstract">
                        <p>Undocumented</p>

                      </div>
                      <div class="declaration">
                        <h4>Declaration</h4>
                        <div class="language">
                          <p class="aside-title">Swift</p>
                          <pre class="highlight swift"><code><span class="kd">public</span> <span class="kd">func</span> <span class="nf">af_setImage</span><span class="p">(</span><span class="k">for</span> <span class="nv">state</span><span class="p">:</span> <span class="kt"><a href="../Typealiases.html#/s:14AlamofireImage12ControlStatea">ControlState</a></span><span class="p">,</span>
                        <span class="nv">url</span><span class="p">:</span> <span class="kt">URL</span><span class="p">,</span>
                        <span class="nv">cacheKey</span><span class="p">:</span> <span class="kt">String</span><span class="p">?</span> <span class="o">=</span> <span class="kc">nil</span><span class="p">,</span>
                        <span class="nv">placeholderImage</span><span class="p">:</span> <span class="kt">UIImage</span><span class="p">?</span> <span class="o">=</span> <span class="kc">nil</span><span class="p">,</span>
                        <span class="nv">serializer</span><span class="p">:</span> <span class="kt"><a href="../Classes/ImageResponseSerializer.html">ImageResponseSerializer</a></span><span class="p">?</span> <span class="o">=</span> <span class="kc">nil</span><span class="p">,</span>
                        <span class="nv">filter</span><span class="p">:</span> <span class="kt"><a href="../Protocols/ImageFilter.html">ImageFilter</a></span><span class="p">?</span> <span class="o">=</span> <span class="kc">nil</span><span class="p">,</span>
                        <span class="nv">progress</span><span class="p">:</span> <span class="kt"><a href="../Classes/ImageDownloader.html">ImageDownloader</a></span><span class="o">.</span><span class="kt">ProgressHandler</span><span class="p">?</span> <span class="o">=</span> <span class="kc">nil</span><span class="p">,</span>
                        <span class="nv">progressQueue</span><span class="p">:</span> <span class="kt">DispatchQueue</span> <span class="o">=</span> <span class="kt">DispatchQueue</span><span class="o">.</span><span class="n">main</span><span class="p">,</span>
                        <span class="nv">completion</span><span class="p">:</span> <span class="p">((</span><span class="kt"><a href="../Typealiases.html#/s:14AlamofireImage15AFIDataResponsea">AFIDataResponse</a></span><span class="o">&lt;</span><span class="kt">UIImage</span><span class="o">&gt;</span><span class="p">)</span> <span class="o">-&gt;</span> <span class="kt">Void</span><span class="p">)?</span> <span class="o">=</span> <span class="kc">nil</span><span class="p">)</span></code></pre>

                        </div>
                      </div>
                    </section>
                  </div>
                </li>
                <li class="item">
                  <div>
                    <code>
                    <a name="/s:So8UIButtonC14AlamofireImageE06af_setC03for10urlRequest8cacheKey011placeholderC010serializer6filter8progress0N5Queue10completionySo14UIControlStateV_0B021URLRequestConvertible_pSSSgSo7UIImageCSgAC0C18ResponseSerializerCSgAC0C6Filter_pSgySo10NSProgressCcSgSo17OS_dispatch_queueCyAP04DataV0VyAtC8AFIErrorOGcSgtF"></a>
                    <a name="//apple_ref/swift/Method/af_setImage(for:urlRequest:cacheKey:placeholderImage:serializer:filter:progress:progressQueue:completion:)" class="dashAnchor"></a>
                    <a class="token" href="#/s:So8UIButtonC14AlamofireImageE06af_setC03for10urlRequest8cacheKey011placeholderC010serializer6filter8progress0N5Queue10completionySo14UIControlStateV_0B021URLRequestConvertible_pSSSgSo7UIImageCSgAC0C18ResponseSerializerCSgAC0C6Filter_pSgySo10NSProgressCcSgSo17OS_dispatch_queueCyAP04DataV0VyAtC8AFIErrorOGcSgtF">af_setImage(for:<wbr>urlRequest:<wbr>cacheKey:<wbr>placeholderImage:<wbr>serializer:<wbr>filter:<wbr>progress:<wbr>progressQueue:<wbr>completion:<wbr>)</a>
                    </code>
                  </div>
                  <div class="height-container">
                    <div class="pointer-container"></div>
                    <section class="section">
                      <div class="pointer"></div>
                      <div class="abstract">
                        <p>Undocumented</p>

                      </div>
                      <div class="declaration">
                        <h4>Declaration</h4>
                        <div class="language">
                          <p class="aside-title">Swift</p>
                          <pre class="highlight swift"><code><span class="kd">public</span> <span class="kd">func</span> <span class="nf">af_setImage</span><span class="p">(</span><span class="k">for</span> <span class="nv">state</span><span class="p">:</span> <span class="kt"><a href="../Typealiases.html#/s:14AlamofireImage12ControlStatea">ControlState</a></span><span class="p">,</span>
                        <span class="nv">urlRequest</span><span class="p">:</span> <span class="kt">URLRequestConvertible</span><span class="p">,</span>
                        <span class="nv">cacheKey</span><span class="p">:</span> <span class="kt">String</span><span class="p">?</span> <span class="o">=</span> <span class="kc">nil</span><span class="p">,</span>
                        <span class="nv">placeholderImage</span><span class="p">:</span> <span class="kt">UIImage</span><span class="p">?</span> <span class="o">=</span> <span class="kc">nil</span><span class="p">,</span>
                        <span class="nv">serializer</span><span class="p">:</span> <span class="kt"><a href="../Classes/ImageResponseSerializer.html">ImageResponseSerializer</a></span><span class="p">?</span> <span class="o">=</span> <span class="kc">nil</span><span class="p">,</span>
                        <span class="nv">filter</span><span class="p">:</span> <span class="kt"><a href="../Protocols/ImageFilter.html">ImageFilter</a></span><span class="p">?</span> <span class="o">=</span> <span class="kc">nil</span><span class="p">,</span>
                        <span class="nv">progress</span><span class="p">:</span> <span class="kt"><a href="../Classes/ImageDownloader.html">ImageDownloader</a></span><span class="o">.</span><span class="kt">ProgressHandler</span><span class="p">?</span> <span class="o">=</span> <span class="kc">nil</span><span class="p">,</span>
                        <span class="nv">progressQueue</span><span class="p">:</span> <span class="kt">DispatchQueue</span> <span class="o">=</span> <span class="kt">DispatchQueue</span><span class="o">.</span><span class="n">main</span><span class="p">,</span>
                        <span class="nv">completion</span><span class="p">:</span> <span class="p">((</span><span class="kt"><a href="../Typealiases.html#/s:14AlamofireImage15AFIDataResponsea">AFIDataResponse</a></span><span class="o">&lt;</span><span class="kt">UIImage</span><span class="o">&gt;</span><span class="p">)</span> <span class="o">-&gt;</span> <span class="kt">Void</span><span class="p">)?</span> <span class="o">=</span> <span class="kc">nil</span><span class="p">)</span></code></pre>

                        </div>
                      </div>
                    </section>
                  </div>
                </li>
                <li class="item">
                  <div>
                    <code>
                    <a name="/s:So8UIButtonC14AlamofireImageE09af_cancelC7Request3forySo14UIControlStateV_tF"></a>
                    <a name="//apple_ref/swift/Method/af_cancelImageRequest(for:)" class="dashAnchor"></a>
                    <a class="token" href="#/s:So8UIButtonC14AlamofireImageE09af_cancelC7Request3forySo14UIControlStateV_tF">af_cancelImageRequest(for:<wbr>)</a>
                    </code>
                  </div>
                  <div class="height-container">
                    <div class="pointer-container"></div>
                    <section class="section">
                      <div class="pointer"></div>
                      <div class="abstract">
                        <p>Cancels the active download request for the image, if one exists.</p>

                      </div>
                      <div class="declaration">
                        <h4>Declaration</h4>
                        <div class="language">
                          <p class="aside-title">Swift</p>
                          <pre class="highlight swift"><code><span class="kd">public</span> <span class="kd">func</span> <span class="nf">af_cancelImageRequest</span><span class="p">(</span><span class="k">for</span> <span class="nv">state</span><span class="p">:</span> <span class="kt"><a href="../Typealiases.html#/s:14AlamofireImage12ControlStatea">ControlState</a></span><span class="p">)</span></code></pre>

                        </div>
                      </div>
                    </section>
                  </div>
                </li>
                <li class="item">
                  <div>
                    <code>
                    <a name="/s:So8UIButtonC14AlamofireImageE016af_setBackgroundC03for3url8cacheKey011placeholderC010serializer6filter8progress0N5Queue10completionySo14UIControlStateV_10Foundation3URLVSSSgSo7UIImageCSgAC0C18ResponseSerializerCSgAC0C6Filter_pSgySo10NSProgressCcSgSo17OS_dispatch_queueCy0B004DataV0VyAuC8AFIErrorOGcSgtF"></a>
                    <a name="//apple_ref/swift/Method/af_setBackgroundImage(for:url:cacheKey:placeholderImage:serializer:filter:progress:progressQueue:completion:)" class="dashAnchor"></a>
                    <a class="token" href="#/s:So8UIButtonC14AlamofireImageE016af_setBackgroundC03for3url8cacheKey011placeholderC010serializer6filter8progress0N5Queue10completionySo14UIControlStateV_10Foundation3URLVSSSgSo7UIImageCSgAC0C18ResponseSerializerCSgAC0C6Filter_pSgySo10NSProgressCcSgSo17OS_dispatch_queueCy0B004DataV0VyAuC8AFIErrorOGcSgtF">af_setBackgroundImage(for:<wbr>url:<wbr>cacheKey:<wbr>placeholderImage:<wbr>serializer:<wbr>filter:<wbr>progress:<wbr>progressQueue:<wbr>completion:<wbr>)</a>
                    </code>
                  </div>
                  <div class="height-container">
                    <div class="pointer-container"></div>
                    <section class="section">
                      <div class="pointer"></div>
                      <div class="abstract">
                        <p>Undocumented</p>

                      </div>
                      <div class="declaration">
                        <h4>Declaration</h4>
                        <div class="language">
                          <p class="aside-title">Swift</p>
                          <pre class="highlight swift"><code><span class="kd">public</span> <span class="kd">func</span> <span class="nf">af_setBackgroundImage</span><span class="p">(</span><span class="k">for</span> <span class="nv">state</span><span class="p">:</span> <span class="kt"><a href="../Typealiases.html#/s:14AlamofireImage12ControlStatea">ControlState</a></span><span class="p">,</span>
                                  <span class="nv">url</span><span class="p">:</span> <span class="kt">URL</span><span class="p">,</span>
                                  <span class="nv">cacheKey</span><span class="p">:</span> <span class="kt">String</span><span class="p">?</span> <span class="o">=</span> <span class="kc">nil</span><span class="p">,</span>
                                  <span class="nv">placeholderImage</span><span class="p">:</span> <span class="kt">UIImage</span><span class="p">?</span> <span class="o">=</span> <span class="kc">nil</span><span class="p">,</span>
                                  <span class="nv">serializer</span><span class="p">:</span> <span class="kt"><a href="../Classes/ImageResponseSerializer.html">ImageResponseSerializer</a></span><span class="p">?</span> <span class="o">=</span> <span class="kc">nil</span><span class="p">,</span>
                                  <span class="nv">filter</span><span class="p">:</span> <span class="kt"><a href="../Protocols/ImageFilter.html">ImageFilter</a></span><span class="p">?</span> <span class="o">=</span> <span class="kc">nil</span><span class="p">,</span>
                                  <span class="nv">progress</span><span class="p">:</span> <span class="kt"><a href="../Classes/ImageDownloader.html">ImageDownloader</a></span><span class="o">.</span><span class="kt">ProgressHandler</span><span class="p">?</span> <span class="o">=</span> <span class="kc">nil</span><span class="p">,</span>
                                  <span class="nv">progressQueue</span><span class="p">:</span> <span class="kt">DispatchQueue</span> <span class="o">=</span> <span class="kt">DispatchQueue</span><span class="o">.</span><span class="n">main</span><span class="p">,</span>
                                  <span class="nv">completion</span><span class="p">:</span> <span class="p">((</span><span class="kt"><a href="../Typealiases.html#/s:14AlamofireImage15AFIDataResponsea">AFIDataResponse</a></span><span class="o">&lt;</span><span class="kt">UIImage</span><span class="o">&gt;</span><span class="p">)</span> <span class="o">-&gt;</span> <span class="kt">Void</span><span class="p">)?</span> <span class="o">=</span> <span class="kc">nil</span><span class="p">)</span></code></pre>

                        </div>
                      </div>
                    </section>
                  </div>
                </li>
                <li class="item">
                  <div>
                    <code>
                    <a name="/s:So8UIButtonC14AlamofireImageE016af_setBackgroundC03for10urlRequest8cacheKey011placeholderC010serializer6filter8progress0O5Queue10completionySo14UIControlStateV_0B021URLRequestConvertible_pSSSgSo7UIImageCSgAC0C18ResponseSerializerCSgAC0C6Filter_pSgySo10NSProgressCcSgSo17OS_dispatch_queueCyAP04DataW0VyAtC8AFIErrorOGcSgtF"></a>
                    <a name="//apple_ref/swift/Method/af_setBackgroundImage(for:urlRequest:cacheKey:placeholderImage:serializer:filter:progress:progressQueue:completion:)" class="dashAnchor"></a>
                    <a class="token" href="#/s:So8UIButtonC14AlamofireImageE016af_setBackgroundC03for10urlRequest8cacheKey011placeholderC010serializer6filter8progress0O5Queue10completionySo14UIControlStateV_0B021URLRequestConvertible_pSSSgSo7UIImageCSgAC0C18ResponseSerializerCSgAC0C6Filter_pSgySo10NSProgressCcSgSo17OS_dispatch_queueCyAP04DataW0VyAtC8AFIErrorOGcSgtF">af_setBackgroundImage(for:<wbr>urlRequest:<wbr>cacheKey:<wbr>placeholderImage:<wbr>serializer:<wbr>filter:<wbr>progress:<wbr>progressQueue:<wbr>completion:<wbr>)</a>
                    </code>
                  </div>
                  <div class="height-container">
                    <div class="pointer-container"></div>
                    <section class="section">
                      <div class="pointer"></div>
                      <div class="abstract">
                        <p>Undocumented</p>

                      </div>
                      <div class="declaration">
                        <h4>Declaration</h4>
                        <div class="language">
                          <p class="aside-title">Swift</p>
                          <pre class="highlight swift"><code><span class="kd">public</span> <span class="kd">func</span> <span class="nf">af_setBackgroundImage</span><span class="p">(</span><span class="k">for</span> <span class="nv">state</span><span class="p">:</span> <span class="kt"><a href="../Typealiases.html#/s:14AlamofireImage12ControlStatea">ControlState</a></span><span class="p">,</span>
                                  <span class="nv">urlRequest</span><span class="p">:</span> <span class="kt">URLRequestConvertible</span><span class="p">,</span>
                                  <span class="nv">cacheKey</span><span class="p">:</span> <span class="kt">String</span><span class="p">?</span> <span class="o">=</span> <span class="kc">nil</span><span class="p">,</span>
                                  <span class="nv">placeholderImage</span><span class="p">:</span> <span class="kt">UIImage</span><span class="p">?</span> <span class="o">=</span> <span class="kc">nil</span><span class="p">,</span>
                                  <span class="nv">serializer</span><span class="p">:</span> <span class="kt"><a href="../Classes/ImageResponseSerializer.html">ImageResponseSerializer</a></span><span class="p">?</span> <span class="o">=</span> <span class="kc">nil</span><span class="p">,</span>
                                  <span class="nv">filter</span><span class="p">:</span> <span class="kt"><a href="../Protocols/ImageFilter.html">ImageFilter</a></span><span class="p">?</span> <span class="o">=</span> <span class="kc">nil</span><span class="p">,</span>
                                  <span class="nv">progress</span><span class="p">:</span> <span class="kt"><a href="../Classes/ImageDownloader.html">ImageDownloader</a></span><span class="o">.</span><span class="kt">ProgressHandler</span><span class="p">?</span> <span class="o">=</span> <span class="kc">nil</span><span class="p">,</span>
                                  <span class="nv">progressQueue</span><span class="p">:</span> <span class="kt">DispatchQueue</span> <span class="o">=</span> <span class="kt">DispatchQueue</span><span class="o">.</span><span class="n">main</span><span class="p">,</span>
                                  <span class="nv">completion</span><span class="p">:</span> <span class="p">((</span><span class="kt"><a href="../Typealiases.html#/s:14AlamofireImage15AFIDataResponsea">AFIDataResponse</a></span><span class="o">&lt;</span><span class="kt">UIImage</span><span class="o">&gt;</span><span class="p">)</span> <span class="o">-&gt;</span> <span class="kt">Void</span><span class="p">)?</span> <span class="o">=</span> <span class="kc">nil</span><span class="p">)</span></code></pre>

                        </div>
                      </div>
                    </section>
                  </div>
                </li>
                <li class="item">
                  <div>
                    <code>
                    <a name="/s:So8UIButtonC14AlamofireImageE019af_cancelBackgroundC7Request3forySo14UIControlStateV_tF"></a>
                    <a name="//apple_ref/swift/Method/af_cancelBackgroundImageRequest(for:)" class="dashAnchor"></a>
                    <a class="token" href="#/s:So8UIButtonC14AlamofireImageE019af_cancelBackgroundC7Request3forySo14UIControlStateV_tF">af_cancelBackgroundImageRequest(for:<wbr>)</a>
                    </code>
                  </div>
                  <div class="height-container">
                    <div class="pointer-container"></div>
                    <section class="section">
                      <div class="pointer"></div>
                      <div class="abstract">
                        <p>Cancels the active download request for the background image, if one exists.</p>

                      </div>
                      <div class="declaration">
                        <h4>Declaration</h4>
                        <div class="language">
                          <p class="aside-title">Swift</p>
                          <pre class="highlight swift"><code><span class="kd">public</span> <span class="kd">func</span> <span class="nf">af_cancelBackgroundImageRequest</span><span class="p">(</span><span class="k">for</span> <span class="nv">state</span><span class="p">:</span> <span class="kt"><a href="../Typealiases.html#/s:14AlamofireImage12ControlStatea">ControlState</a></span><span class="p">)</span></code></pre>

                        </div>
                      </div>
                    </section>
                  </div>
                </li>
              </ul>
            </div>
          </div>
        </section>

      </article>
    </div>
    <section class="footer">
      <p>&copy; 2021 <a class="link" href="http://alamofire.org/" target="_blank" rel="external">Alamofire Software Foundation</a>. All rights reserved. (Last updated: 2021-04-03)</p>
      <p>Generated by <a class="link" href="https://github.com/realm/jazzy" target="_blank" rel="external">jazzy ♪♫ v0.13.6</a>, a <a class="link" href="https://realm.io" target="_blank" rel="external">Realm</a> project.</p>
    </section>
  </body>
</div>
</html>
